Repository navigation
Add optional GameSir G7 Pro 8K battery helper - #2206
Open
derekagraham78 wants to merge 1 commit into
Open
derekagraham78 wants to merge 1 commit into
derekagraham78 wants to merge 1 commit into
Conversation
Owner
|
Thanks for the PR. This is a standalone Python utility, and it already works with mangohud through exec. I don’t see a reason to ship it in mangohud. It makes sense as its own project. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The G7 Pro 8K PC receiver in XInput mode does not expose a battery through sysfs, so
device_battery=gamepadhas no reading. This adds an optional Python helper that reads the GameSir vendor report and supplies the percentage through MangoHud's existingexecoption.The helper runs separately from the overlay. It sends the temporary
0x0f,0xf2reporting heartbeat and reads the battery from byte 36 of report0x12. It does not require Deadband, detach the kernel driver, or change saved controller settings. This keeps USB reads/writes outside MangoHud, as discussed in #2199.Includes setup instructions, an example user service, cached status with stale-reading detection, and tests. Support is limited to the tested
3537:10c6G7 Pro 8K receiver; this does not claim support for every GameSir model or fix PS4-mode firmware reporting. The helper is opt-in and is not automatically installed.Validation:
meson test -C build --no-rebuild 'gamesir battery helper'passed.--oncereturned 100%; the background reader subsequently reported 99%, refreshed the cache, and published Disconnected on SIGTERM. The existing reader service was restored after testing.Protocol reference: https://github.com/broroeror/gamesir-linux-tools
Refs #2199.